package com.kang.c0c.tree.node;


/**
 * 定义了抽象语法树中的while子节点
 * printf		：PRINT		输出
 * 
 * @field:
 * str			：需要输出的字符串
 * expr			：需要输出的表达式
 * 
 * @author kang
 *
 * Feb 6, 2009
 */

public class PrintNode extends Node implements Nodes{
	private LeafNode str;
	private BinaryNode expr;
	
	public PrintNode(){
		this(null,null);
	}
	
	public PrintNode(LeafNode str){
		this(str,null);
	}
	
	public PrintNode(BinaryNode expr){
		this(null,expr);
	}
	
	public PrintNode(LeafNode str,BinaryNode expr){
		super(PRINT);
		this.str = str;
		this.expr = expr;
	}

	public LeafNode getStr() {
		return str;
	}

	public void setStr(LeafNode str) {
		this.str = str;
	}

	public BinaryNode getExpr() {
		return expr;
	}

	public void setExpr(BinaryNode expr) {
		this.expr = expr;
	}
}
